home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / asm / asmlib30.zip / EMS.DOC < prev    next >
Text File  |  1992-06-13  |  2KB  |  80 lines

  1.  
  2. *************************** EXPANDED MEMORY ********************************
  3.  
  4. ASMLIB's EMS subroutines detect and manipulate Expanded Memory hardware
  5. and software.  Expanded memory, when installed in any PC, can help solve
  6. many memory limitation problems.  Call IsEMS before using any other
  7. ASMLIB EMS subroutines.
  8.  
  9. NOTE: ASMLIB's EMS subroutines are under development.  Additional EMS
  10. subroutines may be available by the time this message reaches you.
  11.  
  12. EMS memory is allocated in blocks of 16k pages
  13.  
  14. Error codes returned by EMS functions are:
  15.  
  16.    AH = 0      no error
  17.    AH = 80h    error in memory manager software
  18.    AH = 81h    error in expanded memory hardware
  19.    AH = 84h    bad function code passed to memory manager
  20.    AH = 85h    no EMM handles available
  21.    AH = 89h    you tried to allocate zero pages
  22.  
  23. ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  24.  
  25. EMMVER:     determines EMS driver version
  26. Source:     emmver.asm
  27.  
  28. Call with:  no parameters
  29. Returns:    if CF = 1, AH = EMS error code
  30.             if CF = 0, AH = major version number
  31.                        AL = minor version number
  32. Uses:       AX, flags
  33. Example:
  34.  
  35. include  asm.inc
  36.  
  37. extrn    isems:proc, emmver:proc
  38.  
  39. .code
  40.          .
  41.          .
  42.          .
  43.          call   isems
  44.          jc     no_ems
  45.          or     ah,ah      ; test for EMM error
  46.          jnz    ems_error
  47.          call   emmver     ; get emm version
  48.          jc     ems_error
  49.          cmp    ah,4       ; version 4.x?
  50.          jb     version3x  ; nope, an older EMM version
  51.  
  52.  
  53.  
  54. ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
  55.  
  56. ISEMS:      detects EMS driver
  57. Source:     isems.asm
  58.  
  59. Call with:  no parameters
  60. Returns:    if CF = 1, no Expanded Memory manager installed
  61.             if CF = 0, AH = EMM error code
  62.                if AH = 0, BX = page frame segment address
  63. Uses:       AX, BX, CF
  64. Example:
  65.  
  66. include  asm.inc
  67.  
  68. extrn    isems:proc
  69.  
  70. .code
  71.          .
  72.          .
  73.          .
  74.          call   isems
  75.          jc     no_ems     ; CF = 1 if no EMS memory
  76.          or     ah,ah      ; test for EMM error
  77.          jnz    ems_error
  78.  
  79.  
  80.